namespace Source.Publisher
{
    public class Publisher
    {
        private ISubscribeForMessages subscriber = new NullSubscriber();
        public void Add(ISubscribeForMessages subscriber)
        {
            this.subscriber = subscriber;
        }

        public void Publish(string message)
        {
            subscriber.Receive(message);
        }
    }
}